/*
 * Copyright 2008-2009 the original author or authors.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package ssn.user.service.impl;

import java.util.List;

import org.springframework.stereotype.Repository;

import ssn.user.vo.UserVO;

import egovframework.rte.psl.dataaccess.EgovAbstractDAO;


/**  
 * @Class Name : 
 * @Description : 
 * @Modification Information  
 * @
 * @  수정일      수정자              수정내용
 * @ ---------   ---------   -------------------------------
 * 
 * @since 2013. 09.30
 * @version 1.0
 * @see
 */
@SuppressWarnings("rawtypes")
@Repository("userDAO")
public class UserDAO extends EgovAbstractDAO {

	public String selectUserInfoPk() throws Exception{
		return (String)getSqlMapClientTemplate().queryForObject("selectUserInfoPk");
	}
	public String selectUserCareerInfoPk(String parentKey) throws Exception{
		return (String)selectByPk("selectUserCareerInfoPk", parentKey);
	}
	public String selectUserCertInfoPk(String parentKey) throws Exception{
		return (String)selectByPk("selectUserCertInfoPk", parentKey);
	}
	public String selectUserPicPath(String sau_user_id) throws Exception{
		return (String)selectByPk("selectUserPicPath", sau_user_id);
	}
	public void insertUserInfo(UserVO vo) throws Exception{
		insert("insertUserInfo", vo);
	}
	public void insertUserCareerInfo(UserVO vo) throws Exception{
		insert("insertUserCareerInfo", vo);
	}
	public void insertUserCertInfo(UserVO vo) throws Exception{
		insert("insertUserCertInfo", vo);
	}
	public void updateUserInfo(UserVO vo) throws Exception{
		update("updateUserInfo", vo);
	}
	public void deleteUserInfo(UserVO vo) throws Exception{
		update("deleteUserInfo", vo);
	}
	public void deleteUserPic(String sau_user_id) throws Exception{
		update("deleteUserPic", sau_user_id);
	}
	public List selectUserList(UserVO vo) throws Exception{
		return list("selectUserList", vo);
	}
	public int selectUserListCnt(UserVO vo) throws Exception{
		return Integer.parseInt(selectByPk("selectUserListCnt", vo).toString());
	}
	public UserVO selectUserInfo(UserVO vo) throws Exception{
		return (UserVO)selectByPk("selectUserInfo", vo);
	}
	public List selectUserInfoList() throws Exception{
		return getSqlMapClientTemplate().queryForList("selectUserInfoList");
	}
	public List selectUserCareerInfoList(String parentKey) throws Exception{
		return list("selectUserCareerInfo", parentKey);
	}
	public List selectUserCertInfoList(String parentKey) throws Exception{
		return list("selectUserCertInfo", parentKey);
	}
	public void deleteUserCareer(String parentKey) throws Exception{
		delete("deleteUserCareer", parentKey);
	}
	public void deleteUserCert(String parentKey) throws Exception{
		delete("deleteUserCert", parentKey);
	}
}
